package plantsversuszombies;

import phonegame.*;

public class Player extends GamePlayer {
	
	private int money;
	
	private PlantsVersusZombies game;
	
	public Player(PlantsVersusZombies game) {
		
		this.game = game;
		
		super.setImage("/images/player.png");
		super.setPosition(0, 0);
	}

	public void fire() {
		game.addGameItem(new Plant(game, super.getX(), super.getY()));
		
	}

	public void moveDown() {
		super.movePlayer(super.getX(), super.getY() + 40);
	}

	public void moveLeft() {
		super.movePlayer(super.getX() - 40, super.getY());	
	}

	public void moveRight() {
		super.movePlayer(super.getX() + 40, super.getY());	
	}

	public void moveUp() {
		super.movePlayer(super.getX(), super.getY() - 40);	
	}

	public void pressedButtonA() {
		super.movePlayer(super.getX(), super.getY() + 40);
		
	}

	public void pressedButtonB() {
		super.movePlayer(super.getX(), super.getY() + 40);
		
	}

	public void pressedButtonC() {
		// TODO Auto-generated method stub
		
	}

	public void pressedButtonD() {
		// TODO Auto-generated method stub
		
	}

}
